<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="utf-8">
    <title>支付成功</title>
    <!-- 引入Pacifico手写字体（Google Fonts） -->
    <link rel="preconnect" href="https://fonts.googleapis.com">
    <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
    <link href="https://fonts.googleapis.com/css2?family=Pacifico&display=swap" rel="stylesheet">
    <!-- 引入图标库（成功图标） -->
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
    <style>
        /* 全局样式重置与基础设置 */
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: 'Pacifico', cursive; /* 统一手写字体 */
        }

        body {
            /* 白金主题背景：米白底色+淡金纹理，模拟宣纸鎏金质感 */
            background-color: #F9F7F1;
            background-image:
                /* 淡金网点阵：增强金属光泽感 */
                    radial-gradient(rgba(212, 175, 55, 0.06) 1px, transparent 1px),
                    linear-gradient(135deg, #F9F7F1 0%, #F0EEE6 100%);
            background-size: 25px 25px;
            min-height: 100vh;
            display: flex;
            justify-content: center;
            align-items: center;
            position: relative;
            overflow: hidden;
        }

        /* 背景鎏金光晕：营造高级感氛围 */
        body::before {
            content: "";
            position: fixed;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            width: 700px;
            height: 700px;
            background: radial-gradient(circle, rgba(212, 175, 55, 0.18) 0%, transparent 75%);
            border-radius: 50%;
            z-index: 0;
            filter: blur(80px);
        }

        /* 支付成功容器：白金质感卡片，模拟鎏金镶边效果 */
        .success-container {
            width: 35%;
            min-width: 320px;
            padding: 50px 35px;
            background: rgba(255, 255, 255, 0.95);
            border: 1px solid rgba(212, 175, 55, 0.2);
            border-radius: 16px;
            box-shadow:
                    0 8px 32px rgba(0, 0, 0, 0.06),
                    0 0 15px rgba(212, 175, 55, 0.12) inset; /* 内发光强化鎏金质感 */
            position: relative;
            z-index: 1;
            text-align: center;
        }

        /* 容器顶部鎏金光带：白金主题核心装饰 */
        .success-container::before {
            content: "";
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 3px;
            background: linear-gradient(90deg, #D4AF37, #F9F292, #D4AF37);
            border-top-left-radius: 12px;
            border-top-right-radius: 12px;
        }

        /* 成功图标：鎏金渐变+放大动画，传递喜悦感 */
        .success-icon {
            font-size: 60px;
            margin-bottom: 30px;
            /* 图标鎏金渐变，增强金属质感 */
            background: linear-gradient(90deg, #D4AF37, #F9F292);
            -webkit-background-clip: text;
            background-clip: text;
            color: transparent;
            text-shadow: 0 0 10px rgba(212, 175, 55, 0.2);
            /* 入场动画：缓慢放大，避免生硬 */
            animation: scaleIn 0.8s ease forwards;
            opacity: 0;
            transform: scale(0.8);
        }

        /* 标题样式：深墨色文字+鎏金阴影，契合手写质感 */
        .success-container h2 {
            color: #3A362E;
            font-size: 32px;
            margin-bottom: 15px;
            letter-spacing: 1.5px;
            text-shadow: 0 1px 2px rgba(212, 175, 55, 0.1);
            /* 延迟入场，营造层次感 */
            animation: fadeIn 0.8s ease 0.3s forwards;
            opacity: 0;
        }

        /* 支付金额样式：鎏金渐变文字+突出显示，成为视觉焦点 */
        .payment-amount {
            font-size: 48px;
            margin: 25px 0;
            /* 金额鎏金渐变，比图标更深，增强视觉权重 */
            background: linear-gradient(90deg, #C29E2E, #D4AF37);
            -webkit-background-clip: text;
            background-clip: text;
            color: transparent;
            font-weight: normal;
            /* 金额跳动动画：模拟“确认到账”的愉悦感 */
            animation: bounceIn 1s ease 0.6s forwards;
            opacity: 0;
            transform: translateY(20px);
        }

        /* 辅助文本：淡墨色文字+柔和效果，传递温馨提示 */
        .success-desc {
            color: #6B665D;
            font-size: 18px;
            margin-bottom: 40px;
            letter-spacing: 0.5px;
            line-height: 1.4;
            animation: fadeIn 0.8s ease 0.9s forwards;
            opacity: 0;
        }

        /* 首页链接：鎏金底色按钮，强化点击引导 */
        .home-link {
            display: inline-block;
            padding: 12px 40px;
            background: linear-gradient(90deg, #D4AF37, #C29E2E);
            color: #FFFFFF;
            text-decoration: none;
            font-size: 20px;
            border-radius: 8px;
            transition: all 0.3s ease;
            position: relative;
            overflow: hidden;
            border: 1px solid #D4AF37;
            /* 延迟入场，最后引导用户操作 */
            animation: fadeUp 0.8s ease 1.2s forwards;
            opacity: 0;
            transform: translateY(20px);
        }

        /* 链接 hover 光效：鎏金流动效果，模拟金属反光 */
        .home-link::after {
            content: "";
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
            transition: left 0.6s ease;
        }

        .home-link:hover {
            background: linear-gradient(90deg, #C29E2E, #B08E25);
            transform: translateY(-3px);
            box-shadow: 0 6px 16px rgba(212, 175, 55, 0.25);
        }

        .home-link:hover::after {
            left: 100%;
        }

        .home-link:active {
            transform: translateY(0);
            box-shadow: 0 3px 8px rgba(212, 175, 55, 0.18);
        }

        /* 动画定义：确保节奏舒缓，契合成功场景的愉悦感 */
        @keyframes scaleIn {
            to {
                opacity: 1;
                transform: scale(1);
            }
        }

        @keyframes fadeIn {
            to {
                opacity: 1;
            }
        }

        @keyframes bounceIn {
            0% {
                opacity: 0;
                transform: translateY(20px);
            }
            70% {
                transform: translateY(-10px);
            }
            100% {
                opacity: 1;
                transform: translateY(0);
            }
        }

        @keyframes fadeUp {
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        /* 响应式适配：小屏幕优化，确保移动端体验一致 */
        @media (max-width: 768px) {
            .success-container {
                width: 85%;
                padding: 40px 25px;
            }

            .success-icon {
                font-size: 50px;
            }

            .success-container h2 {
                font-size: 28px;
            }

            .payment-amount {
                font-size: 40px;
            }

            .success-desc {
                font-size: 16px;
            }

            .home-link {
                padding: 10px 35px;
                font-size: 18px;
                width: 100%; /* 小屏幕按钮全屏宽，方便点击 */
            }
        }
    </style>
</head>
<body>
<div class="success-container">
    <!-- 成功图标：鎏金渐变，传递成功信号 -->
    <i class="fas fa-check-circle success-icon"></i>
    <!-- 标题：明确支付结果 -->
    <h2>支付成功！</h2>
    <!-- 支付金额：保留原渲染逻辑 #(session.payBook.total) -->
    <p class="payment-amount">¥#(session.payBook.total)</p>
    <!-- 辅助说明：温馨提示，引导后续操作 -->
    <p class="success-desc">订单已确认，可返回首页继续浏览或查看订单</p>
    <!-- 首页链接：保留原跳转地址 /book/index -->
    <a href="/book/index" class="home-link">返回首页</a>
</div>
</body>
</html>